<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:ui="http://java.sun.com/jsf/facelets">
    <h:head>
        <title>Edit Profile</title>
    </h:head>
    <h:body>
        <ui:composition template="/Template/newTemplate.xhtml">
            <ui:define name="content">
                <table>
                    <tr>
                        <th></th>
                        <th>Update Your Profile</th>
                    </tr>
                    <h:form>
                        <tr>
                            <td><h:outputText value="First Name"></h:outputText></td>
                            <td><h:inputText value="#{editProfileBean.firstName}"></h:inputText></td>
                        </tr>
                        <tr>
                            <td><h:outputText value="Last Name"></h:outputText></td>
                            <td><h:inputText value="#{editProfileBean.surName}"></h:inputText></td>
                        </tr>
                        <tr>
                            <td><h:outputText value="Address"></h:outputText></td>
                            <td><h:inputText value="#{editProfileBean.address}"></h:inputText></td>
                        </tr>
                        <tr>
                            <td><h:outputText value="Zipcode"></h:outputText></td>
                            <td><h:inputText value="#{editProfileBean.zipcode}"></h:inputText></td>
                        </tr>
                        <tr>
                            <td><h:outputText value="City"></h:outputText></td>
                            <td><h:inputText value="#{editProfileBean.city}"></h:inputText></td>
                        </tr>
                        <tr>
                            <td><h:outputText value="Country"></h:outputText></td>
                            <td><h:inputText value="#{editProfileBean.country}"></h:inputText></td>
                        </tr>
                        <tr>
                            <td></td>
                            <td align="right">
                                <h:commandButton action="#{editProfileBean.updateProfile}" value="Update Profile"/>
                            </td>
                        </tr>
                    </h:form>
                    <tr></tr>
                    <h:form>
                        <tr>
                            <th></th>
                            <th>Change Your Password</th>
                        </tr>
                        <tr>
                            <td><h:outputText value="Old Password"/></td>
                            <td><h:inputSecret value="#{editProfileBean.oldPassword}"/></td>
                        </tr>
                        <tr>
                            <td><h:outputText value="New Password"/></td>
                            <td><h:inputSecret value="#{editProfileBean.password}"/></td>
                        </tr>
                        <tr>
                            <td><h:outputText value="Confirm Password"/></td>
                            <td><h:inputSecret value="#{editProfileBean.confirmPassword}"/></td>
                        </tr>
                        <tr>
                            <td></td>
                            <td align="right">
                                <h:commandButton action="#{editProfileBean.updatePassword}" value="Update Password"/>
                            </td>
                        </tr>

                    </h:form>
                </table>
            </ui:define>
        </ui:composition>
    </h:body>
</html>

